<meta charset="UTF-8">
<div id="io-record">
    <div class="demo-spin-container" v-if="isSpin">
        <Spin size="large" fix></Spin>
    </div>
    <Row style="margin:10px;height: 32px;">
        <div class="fl">
            <div>{{$t("reportForm.selectDev")}}:&nbsp;</div>
        </div>
        <div style="position: relative;width: 300px;" class="fl">
            <div class="search-wrapper" v-click-outside.capture="onClickOutside">
                <i-input v-model.trim="sosoValue" icon="ios-close-circle-outline" @on-change="sosoValueChange" @on-focus="focus" :placeholder="placeholder" @on-click="onClickIcon"></i-input>
                <transition name="fade">
                    <div class="search-item-wrapper" v-show="isShowMatchDev">
                        <ul id="ztree" class="ztree"></ul>
                    </div>
                </transition>
            </div>
        </div>
        <div style="margin-left:20px;" class="fl">
            {{$t("reportForm.selected")}}: <span v-text="selectedCount"></span>
        </div>
        <div style="margin-left:20px;position: relative;" class="fl">
            <s-checkbox style="width:200px;" @change-io="onIoChange"></s-checkbox>
        </div>
        <div style="margin-left:20px;" class="fl">
            <i-button @click="onClickQuery" icon="ios-search">{{$t("reportForm.query")}}</i-button>
        </div>
        <div style="margin-left:20px;" class="rt">
            <i-button @click="exportData" type="primary">{{$t("reportForm.exportData")}}</i-button>
        </div>
    </Row>
    <Row style="margin:10px;height: 35px;">
        <div class="fl">
            <span>{{$t("reportForm.selectTime")}}:</span>
            <date-picker type="daterange" :value="dateVal" :editable="false" :clearable="false" @on-change="onChange" show-week-numbers style="width:300px" placement="bottom-start"></date-picker>
        </div>
        <div style="margin-left: 20px;" class="spans-wrap fl">
            <span class="cursor-pointer" @click="handleSelectdDate(0)" :style="{color: dayNumberType == 0 ? '#2D8CF0' : '#515A6E'}">{{$t("reportForm.toDay")}}</span> <b>｜</b>
            <span class="cursor-pointer" @click="handleSelectdDate(1)" :style="{color: dayNumberType == 1 ? '#2D8CF0' : '#515A6E'}">{{$t("reportForm.yesterDay")}}</span> <b>｜</b>
            <span class="cursor-pointer" @click="handleSelectdDate(3)" :style="{color: dayNumberType == 3 ? '#2D8CF0' : '#515A6E'}">{{$t("reportForm.threeDays")}}</span> <b>｜</b>
            <span class="cursor-pointer" @click="handleSelectdDate(7)" :style="{color: dayNumberType == 7 ? '#2D8CF0' : '#515A6E'}">{{$t("reportForm.sevenDays")}}</span>
        </div>
    </Row>
    <div style="margin:10px;">
        <Tabs :value="activeTab" @on-click="onClickTab">
            <Tab-pane :label="$t('reportForm.ioStatistics')" name="tabTotal">
                <i-table ref="totalTable" size="small" :columns="allIoColumns" :data="allIoTableData" :height="lastTableHeight" :loading="loading"></i-table>
            </Tab-pane>
            <Tab-pane :label="$t('reportForm.ioDuration')" name="tabDetail">
                <i-table ref="detailTable" size="small" :columns="columns" :height="lastTableHeight" :data="tableData" :loading="loading"></i-table>
            </Tab-pane>
        </Tabs>
    </div>
    <transition name="fade">
        <div v-show="mapModal" class="posi-map-wraper">
            <div class="map-modal" @click="mapModal=false"></div>
            <div class="inner-map-wraper">
                <div class="posi-map-title">
                    {{$t("reportForm.seePosi")}}
                    <div class="map-close"></div>
                </div>
                <div id="posi-map"></div>
            </div>
        </div>
    </transition>
</div>